<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>2-32vue生命周期之实例创建</title>
</head>
<body>
<div id="app">
    {{msg}}
</div>
</body>
<script src="./js/vue.js"></script>
<script>
    new Vue({
        el:'#app',
        data:{
            msg:'zhangsan'
        },
        beforeCreate(){
            console.log("create instance before")
            console.log(this.$data.msg)
        },
        created(){
            console.log("实例创建之后")
            console.log(this.$data.msg)
        }
    })
</script>
</html>